package com.dubbo.dubboconsumer.controllers;

import com.dubbo.services.HelloService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Classname HelloController
 * @Description TODO
 * @Date 2020/2/16 10:53
 * @Created by apple
 */
@RestController
public class HelloController {

    @Resource
    HelloService helloService;

    @GetMapping("/consumer")
    public String consumer() {
        System.out.println("hello");
        return helloService.sayHello("hello");
    }

}
